<template>
  <div>
    <router-view />
    <van-tabbar route v-model="active" @change="onChange">
      <van-tabbar-item replace to="/homeIndex" icon="wap-home">首页</van-tabbar-item>
      <van-tabbar-item replace to="/history" icon="column">订单</van-tabbar-item>
      <van-tabbar-item replace to="/walletindex" icon="pending-payment">钱包</van-tabbar-item>
      <van-tabbar-item replace to="/newIndex" icon="volume">消息</van-tabbar-item>
      <van-tabbar-item replace to="/personalUser" icon="manager">我的</van-tabbar-item>
    </van-tabbar>
  </div>
</template>

<script>
export default {
  name:"Tabbar",
  data() {
    return {
      active: 0,
    };
  },
  methods: {
    onChange(index) {
      this.active=index
    },
  },
};
</script>
<style>

</style>
